Option Strict Off
Option Explicit On
Friend Class stiff
	Inherits System.Windows.Forms.Form
	Private Sub stiff_Load(ByVal eventSender As System.Object, ByVal eventArgs As System.EventArgs) Handles MyBase.Load
		Dim i, j As Integer
		Dim aux As String
		Dim numfil As Integer
		Dim linea As String
		
		'On Error GoTo ErrSub
		
		'lbl1.Clear 'elimina el contenido de la lista
		numfil = FreeFile 'numero de archivo libre
		'abrir el archivo para leer
		FileOpen(numfil, "D:\PROYECTO_CASA\software\casa\v1.3\titulo_nuevoParam.txt", OpenMode.Input)
		i = 0
		Do While Not EOF(numfil)
			
			'Lee la linea
			linea = LineInput(numfil)
			If i = 0 Then
				lbl1(i).Text = linea
				txt(i).Visible = True
			Else
				If linea <> "ENSAYO MICROBIOLOGICO" Then
					txt.Load(i)
					lbl1.Load(i)
					If linea <> "TIPO ENSAYO" Then
						txt(i).Top = VB6.TwipsToPixelsY(VB6.PixelsToTwipsY(txt(i - 1).Top) + VB6.PixelsToTwipsY(txt(i - 1).Height)) '300 '270
						txt(i).Visible = True
						lbl1(i).Top = VB6.TwipsToPixelsY(VB6.PixelsToTwipsY(lbl1(i - 1).Top) + VB6.PixelsToTwipsY(txt(i - 1).Height)) '300 '270
						lbl1(i).Text = linea
						lbl1(i).Visible = True
					Else
						txt(i).Top = VB6.TwipsToPixelsY(VB6.PixelsToTwipsY(txt(i - 1).Top) + VB6.PixelsToTwipsY(txt(i - 1).Height) + 300)
						opt_si.Visible = True : opt_si.Top = VB6.TwipsToPixelsY(VB6.PixelsToTwipsY(txt(i - 1).Top) + 700)
						opt_no.Visible = True : opt_no.Left = VB6.TwipsToPixelsX(5160) : opt_no.Top = VB6.TwipsToPixelsY(VB6.PixelsToTwipsY(txt(i - 1).Top) + 700)
						lbl1(i).Top = VB6.TwipsToPixelsY(VB6.PixelsToTwipsY(lbl1(i - 1).Top) + 300) 'txt(i - 1).Height - 300 '300 '270
						lbl1(i).Text = linea
						lbl1(i).Visible = True
						'        txt(i).Top = txt(i - 1).Top + 300
					End If 'tipo ensayo
					
					
					
				End If
				
			End If
			If linea <> "ENSAYO MICROBIOLOGICO" Then i = i + 1
		Loop 
		
		''For i = 0 To 4
		''If i = 0 Then
		''txt(i).Visible = True
		'lbl1(i).Caption = UCase("parametro")
		'txt(i).BackColor = vbWhite
		''Else
		''Load txt(i)
		'txt(i).BackColor = vbWhite
		''txt(i).Top = txt(i - 1).Top + txt(i - 1).Height '300 '270
		''txt(i).Visible = True
		''End If
		''Next i
	End Sub
End Class